<!DOCTYPE html>
<html>

<head>
  <meta charset="utf-8">
  <meta name="viewport" content="width=device-width,initial-scale=1.0">
  <title>双向绑定</title>
  <script src="https://unpkg.com/vue@3/dist/vue.global.js"></script>
</head>

<body>
  <div id="app">
    <input type="text" v-model="message">
    <p>输入的内容是:{{message}}</p>
  </div>
  <script type="module">
    const { createApp, ref } = Vue;

    createApp({
      setup() {
        const message = ref('Hello vue!')
        return {
          message
        }
      }
    }).mount('#app');
  </script>

</body>

</html>